/*
 * This file is part of VLCJ.
 *
 * VLCJ is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * VLCJ is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with VLCJ.  If not, see <http://www.gnu.org/licenses/>.
 * 
 * Copyright 2009, 2010, 2011 Caprica Software Limited.
 */

package uk.co.caprica.vlcj.dbus.sessionmanager;

import org.freedesktop.dbus.DBusInterface;
import org.freedesktop.dbus.DBusInterfaceName;
import org.freedesktop.dbus.UInt32;

/**
 * Specification for the Gnome Session Manager DBus Interface.
 * <p>
 * In the "gnome-session" source package the DBus specification comes from
 * "org.gnome.SessionManager.xml".
 * <p>
 * This is a <em>partial</em> specification, other functions are available.
 */
@DBusInterfaceName("org.gnome.SessionManager")
public interface SessionManager extends DBusInterface {

  /**
   * Inhibit the session manager.
   * 
   * @param applicationName application name
   * @param xid top-level window id
   * @param inhibitReason message stating why the session manager is inhibited
   * @param flags
   * @return cookie, used later to uninhibit the session manager
   */
  UInt32 Inhibit(String applicationName, UInt32 xid, String inhibitReason, UInt32 flags);

  /**
   * Uninhibit the session manager.
   * 
   * @param cookie cookie, obtained earlier when inhibiting the session manager
   */
  void Uninhibit(UInt32 cookie);
}